import util from '@/utils/request'
const fetch = util.ajax


//新增分类API
export function addTopic(data) {
    return fetch({
        url: 'blog/topic',
        method: 'post',
        data: data
    })
}
//查询分类列表
export function qryTopics(data) {
    return fetch({
        url: '/blog/topic/list',
        method: 'get',
        params: data
    })
}
//更新分类
export function updTopic(data) {
    return fetch({
        url: '/blog/topic',
        method: 'put',
        data: data
    })
}
//删除分类
export function delTopic(data) {
    return fetch({
        url: '/blog/topic',
        method: 'delete',
        params: data
    })
}
